// 假设 config 中包含 APP_PORT 和 APP_HOST 配置
import config from "../src/app/config.ts";
import app from "./app/index.ts";

app.listen(config.APP_PORT, () => {
  const host = config.APP_HOST || "localhost";
  const protocol = "http";
  console.log(process.env.NODE_ENV, "");
  console.log(`'koa_db'服务器在${config.APP_PORT}端口启动成功`);
  console.log(`运行地址: ${protocol}://${host}:${config.APP_PORT}`);
  console.log(
    `Swagger 文档: ${protocol}://${host}:${config.APP_PORT}/api/swagger-html`
  );
});
